#ifndef PARAM_WIDGET_CONVENTIONAL_H
#define PARAM_WIDGET_CONVENTIONAL_H

#include <QWidget>
#include <iostream>
#include "common/types.h"
#include "common/parameters.h"

class Airfoil_dialog;

namespace Ui {
    class Param_widget_conventional;
}

class Param_widget_conventional: public QWidget
{
    Q_OBJECT

public:
    explicit Param_widget_conventional(QWidget *parent = 0);
    ~Param_widget_conventional();
    void load_airfoil_value(QVector<Point *> point_list,QString file_name, int button_pressed);
    Airfoil_dialog *get_airfoil_dialog();
    void retranslateUi();
    int last_button_pressed;
    bool getClosed();

signals:
    void s_load_parameters(ParametersWidget *params, Airfoils_curve_map *af_reference_curve, int module);

private slots:
    void get_widget_parameters();
    void load_images();
    void set_reg_exp();
    void front_view_wing_clicked();
    void top_view_wing_clicked();
    void set_signal_buttons();
    void load_fwing_button();
    void load_bwing_button();
    void load_lwing_button();
    void load_forwardWingtip_button();
    void load_backwardWingtip_button();
    void load_joinedWing_button();
    void set_fwing(QString file_name);
    void set_bwing(QString file_name);
    void set_forward_wingtip(QString file_name);
    void set_joinedWing(QString file_name);
    void show_airfoil_dialog();
    void control_parameteres();

private:
    Ui::Param_widget_conventional *ui;
    Airfoils_curve_map *af_reference_curve;
    Airfoil_dialog *ad;
    bool closed;
    bool control_param();
    void charge_test();
    bool valid_file(QString nameFile);


};

#endif // PARAM_WIDGET_CONVENTIONAL_H
